package com.zzx.auth.biz;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zzx.auth.mapper.SysMenuMapper;
import com.zzx.auth.model.SysMenu;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Set;

/**
 * 系统菜单仓储层
 */
@Service
public class SysMenuBiz extends ServiceImpl<SysMenuMapper, SysMenu> {
    @Autowired
    private SysMenuMapper sysMenuMapper;

    /**
     * 获取菜单
     *
     * @param username 用户名
     * @return 菜单表单
     */
    public Set<String> getMenuPermsByUserName(String username) {
        return sysMenuMapper.getMenuPermsByUserName(username);
    }
}
